package org.example;

import java.util.function.LongSupplier;

/**
 * @author lijinting01
 */
class SnowflakeIdWorkerV1 extends SnowflakeIdWorker {

  SnowflakeIdWorkerV1(long epoch, long dataCenterId, long workerId,
      LongSupplier sequenceSupplier) {
    super(epoch, dataCenterId, workerId, sequenceSupplier);
  }

  @Override
  protected int defineTimestampBits() {
    return 41;
  }

  @Override
  protected int defineDataCenterBits() {
    return 5;
  }

  @Override
  protected int defineWorkerIdBits() {
    return 5;
  }

  @Override
  protected int defineSequenceBits() {
    return 12;
  }
}
